package cn.tedu.nybikeT.pojo;

import java.io.Serializable;

/**
 * 站点安全信息类
 * @author rory
 *
 */
public class StationSecurityVO implements Serializable{

	private static final long serialVersionUID = 4434699462575597824L;
	
	private StationInfoDO stationBasicInfo;//站点基本数据（名称，id，经纬度
	private int crashNumber;//某年某月该站点方圆n公里发生的事故数
	private int injuredNumber;//某年该站点方圆n公里所有事故的受伤人数
	private int killedNumber;//某年该站点方圆n公里所有事故的死亡人数
	private double dangerIndex;//危险指数
	
	public StationSecurityVO() {
		super();
		// TODO Auto-generated constructor stub
	}

	public StationSecurityVO(StationInfoDO stationBasicInfo, int crashNumber, int injuredNumber, int killedNumber,
			double dangerIndex) {
		super();
		this.stationBasicInfo = stationBasicInfo;
		this.crashNumber = crashNumber;
		this.injuredNumber = injuredNumber;
		this.killedNumber = killedNumber;
		this.dangerIndex = dangerIndex;
	}

	@Override
	public String toString() {
		return "StationSecurityVO [stationBasicInfo=" + stationBasicInfo + ", crashNumber=" + crashNumber
				+ ", injuredNumber=" + injuredNumber + ", killedNumber=" + killedNumber + ", dangerIndex=" + dangerIndex
				+ "]";
	}

	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + crashNumber;
		long temp;
		temp = Double.doubleToLongBits(dangerIndex);
		result = prime * result + (int) (temp ^ (temp >>> 32));
		result = prime * result + injuredNumber;
		result = prime * result + killedNumber;
		result = prime * result + ((stationBasicInfo == null) ? 0 : stationBasicInfo.hashCode());
		return result;
	}

	@Override
	public boolean equals(Object obj) {
		if (this == obj)
			return true;
		if (obj == null)
			return false;
		if (getClass() != obj.getClass())
			return false;
		StationSecurityVO other = (StationSecurityVO) obj;
		if (crashNumber != other.crashNumber)
			return false;
		if (Double.doubleToLongBits(dangerIndex) != Double.doubleToLongBits(other.dangerIndex))
			return false;
		if (injuredNumber != other.injuredNumber)
			return false;
		if (killedNumber != other.killedNumber)
			return false;
		if (stationBasicInfo == null) {
			if (other.stationBasicInfo != null)
				return false;
		} else if (!stationBasicInfo.equals(other.stationBasicInfo))
			return false;
		return true;
	}

	/**
	 * @return the stationBasicInfo
	 */
	public StationInfoDO getStationBasicInfo() {
		return stationBasicInfo;
	}

	/**
	 * @param stationBasicInfo the stationBasicInfo to set
	 */
	public void setStationBasicInfo(StationInfoDO stationBasicInfo) {
		this.stationBasicInfo = stationBasicInfo;
	}

	/**
	 * @return the crashNumber
	 */
	public int getCrashNumber() {
		return crashNumber;
	}

	/**
	 * @param crashNumber the crashNumber to set
	 */
	public void setCrashNumber(int crashNumber) {
		this.crashNumber = crashNumber;
	}

	/**
	 * @return the injuredNumber
	 */
	public int getInjuredNumber() {
		return injuredNumber;
	}

	/**
	 * @param injuredNumber the injuredNumber to set
	 */
	public void setInjuredNumber(int injuredNumber) {
		this.injuredNumber = injuredNumber;
	}

	/**
	 * @return the killedNumber
	 */
	public int getKilledNumber() {
		return killedNumber;
	}

	/**
	 * @param killedNumber the killedNumber to set
	 */
	public void setKilledNumber(int killedNumber) {
		this.killedNumber = killedNumber;
	}

	/**
	 * @return the dangerIndex
	 */
	public double getDangerIndex() {
		return dangerIndex;
	}

	/**
	 * @param dangerIndex the dangerIndex to set
	 */
	public void setDangerIndex(double dangerIndex) {
		this.dangerIndex = dangerIndex;
	}

	/**
	 * @return the serialversionuid
	 */
	public static long getSerialversionuid() {
		return serialVersionUID;
	}
	
	
	
}
